<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>太极</title>
    <style>
        * {
            margin: 0;
            padding: 0;
        }

        body {
            background-color: #ccc;
        }

        div {
            width: 0px;
            height: 300px;
            border-left: 150px solid #fff;
            border-right: 150px solid #000;
            margin: auto;
            border-radius: 50%;
        }

        @keyframes turnZ {
            0% {
                transform: rotateZ(0deg);
            }

            20% {
                transform: rotateZ(70deg);
            }

            40% {
                transform: rotateZ(140deg);
            }

            60% {
                transform: rotateZ(210deg);
            }

            80% {
                transform: rotateZ(280deg);
            }

            100% {
                transform: rotateZ(360deg);
            }
        }


        div {
            animation-name: turnZ;
            animation-duration: 2s;
            animation-iteration-count: infinite;
            animation-timing-function: linear;
        }

        div::before {
            content: "";
            display: block;
            width: 150px;
            height: 150px;
            background-color: #fff;
            /* 只能改变左和上，以左上角为基准 */
            margin-left: -75px;
            border-radius: 50%;
            border: 60px solid #000;
            /* 适应盒子边框 */
            box-sizing: border-box;
        }

        div::after {
            content: "";
            display: block;
            width: 150px;
            height: 150px;
            border-radius: 50%;
            background-color: #000;
            margin-left: -75px;
            border: 60px solid #fff;
            box-sizing: border-box;
        }
    </style>
</head>

<body>
    <div></div>
</body>


</html>